package com.example.demo.entity;

import com.fasterxml.jackson.annotation.JsonFormat;
import lombok.Data;

import javax.validation.Valid;
import javax.validation.constraints.NotBlank;
import javax.validation.constraints.NotNull;
import java.util.Date;
import java.util.List;

@Data
public class AlarmData {

    @NotBlank(message = "布控编号不能为空")
    private String controlCode;

    @NotNull(message = "业务算法模式不能为空")
    private String flowMode;

    private String flowCode;

    private String flowName;

    @NotNull(message = "画框类型不能为空")
    private String drawType;

    private String flag;

    @NotBlank(message = "转发app不能为空")
    private String streamApp;

    @NotBlank(message = "转发name不能为空")
    private String streamName;

    @NotBlank(message = "摄像头编号不能为空")
    private String streamCode;

    private String streamNickname;

    private String desc;

    @NotNull(message = "视频数量不能为空")
    private String videoCount;

    @Valid
    @NotNull(message = "视频数组不能为空")
    private List<VideoInfo> videoArray;

    @NotNull(message = "图片数量不能为空")
    private String imageCount;

    @Valid
    @NotNull(message = "图片数组不能为空")
    private List<ImageInfo> imageArray;

    @Valid
    @NotNull(message = "图片检测数据不能为空")
    private List<List<ImageDetect>> imageDetects;

    @Valid
    @NotNull(message = "扩展参数不能为空")
    private ExtendParams extendParams;

    @JsonFormat(pattern = "yyyy/MM/dd HH:mm:ss", timezone = "GMT+8")
    private Date createTime;
}    